import Vue from 'vue'
import Router from 'vue-router'
import Login from '@/components/Login'
import index from '../components/index.vue'
import user from '../components/user.vue'
import userList from '../components/userList.vue'
import shoperList from '../components/shoperList.vue'
import storeList from '../components/storeList.vue'
import storeManage from '../components/storeManage.vue'
import powerManage from '../components/powerManage.vue'
//黄
import storage from '../components/storage.vue'
import storageAdmin from '../components/storageAdmin.vue'
import suppliersCommon from '../components/suppliersCommon.vue'
import suppliers from '../components/suppliers.vue'
//张
import action from '../components/action.vue'
import goods from '../components/goods.vue'
import goodsAdd from '../components/goodsAdd.vue'
//尹
import goodsList from '../components/goodsList.vue'
import goodsOperation from '../components/goodsOperation.vue'
import goodsRecords from '../components/goodsRecords.vue'
import saleChart from '../components/saleChart.vue'

Vue.use(Router)

export default new Router({
  mode:"history",
  routes: [
    {
      path: '/',
      name: 'Login',
      meta:{"isLogin":true},
      component: Login
    },
    {
      path: '/index',
      name: 'index',
      meta:{"isLogin":false},
      component: index,
      children:[
        {
          path: 'user',
          name: 'user',
          meta:{"isLogin":false},
          component: user
        },
        {
          path: 'userList',
          name: 'userList',
          meta:{"isLogin":false},
          component: userList
        },
        {
          path: 'shoperList',
          name: 'shoperList',
          meta:{"isLogin":false},
          component: shoperList
        },
        {
          path: 'storeList',
          name: 'storeList',
          meta:{"isLogin":false},
          component: storeList
        },
        {
          path: 'storeManage',
          name: 'storeManage',
          meta:{"isLogin":false},
          component: storeManage
        },
        {
          path: 'powerManage',
          name: 'powerManage',
          meta:{"isLogin":false},
          component: powerManage
        },
        {
          path: 'storage',
          name: 'storage',
          meta:{"isLogin":false},
          component: storage
        },
        {
          path: 'storageAdmin',
          name: 'storageAdmin',
          meta:{"isLogin":false},
          component: storageAdmin
        },
        {
          path: 'suppliersCommon',
          name: 'suppliersCommon',
          meta:{"isLogin":false},
          component: suppliersCommon
        },
        {
          path: 'suppliers',
          name: 'suppliers',
          meta:{"isLogin":false},
          component: suppliers
        },
        {
          path: 'goods',
          name: 'goods',
          meta:{"isLogin":false},
          component: goods
        },
        {
          path: 'action',
          name: 'action',
          meta:{"isLogin":false},
          component: action
        },
        {
          path: 'goodsList',
          name: 'goodsList',
          meta:{"isLogin":false},
          component: goodsList
        },
        {
          path: 'goodsOperation',
          name: 'goodsOperation',
          meta:{"isLogin":false},
          component: goodsOperation
        },
        {
          path: 'goodsRecords',
          name: 'goodsRecords',
          meta:{"isLogin":false},
          component: goodsRecords
        },
        {
          path: 'saleChart',
          name: 'saleChart',
          meta:{"isLogin":false},
          component: saleChart
        },
				{
					path: 'goodsAdd',
					name: 'goodsAdd',
					meta:{"isLogin":false},
					component: goodsAdd
				}
      ]
    },
  ]
})
